/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package Classes;

import java.io.Serializable;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;

/**
 *
 * @author BRUNA
 */

@Entity
@Table (name="tbl_unidademedida")
@SequenceGenerator(name = "seq_unimed", sequenceName = "seq_unimed", allocationSize = 1)
public class UniMedidaClass implements Serializable{
    @Id
    @GeneratedValue(generator = "seq_unimed", strategy = GenerationType.TABLE)
    
    private int id;
    private String descricao;
    private String sigla;

    public UniMedidaClass() {
    }

    public UniMedidaClass(int id) {
        this.id = id;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getDescricao() {
        return descricao;
    }

    public void setDescricao(String descricao) {
        this.descricao = descricao;
    }

    public String getSigla() {
        return sigla;
    }

    public void setSigla(String sigla) {
        this.sigla = sigla;
    }
    
    @Override
    public String toString() {
        return (sigla);
    } 
}
